<?xml version="1.0" encoding="ISO-8859-1"?>
<!DOCTYPE composition PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:jsp="http://java.sun.com/JSP/Page"
      xmlns:f="http://java.sun.com/jsf/core"
      xmlns:h="http://java.sun.com/jsf/html"
      xmlns:ui="http://java.sun.com/jsf/facelets"
      xmlns:a4j="http://richfaces.org/a4j"
      xmlns:rich="http://richfaces.org/rich">

    <ui:composition template="../template/portal_template.xhtml">
        <ui:define name="content" >
            <h3>Nova Disciplina</h3><br/>
                      <h:form>
                        <h:inputHidden id="validateCreateField" validator="#{disciplina.validateCreate}" value="value"/>
                        <div class="field">
                            <label>Nome</label><br/><rich:spacer height="10px"></rich:spacer><br/>
                            <h:inputText size="25" maxlength="50"
                                         value="#{disciplina.disciplina.nome}"
                                         required="true" requiredMessage="#{messages.nome}"/>
                        </div><br/><br/>
                        <div class="field">
                            <label>Codigo</label><br/><rich:spacer height="10px"></rich:spacer><br/>
                            <h:inputText size="25" maxlength="7"
                                         value="#{disciplina.disciplina.codigo}"
                                         required="true" requiredMessage="#{messages.codigo}"/>
                        </div><br/><br/>
                        <div class="field">
                            <label>Departamento</label><br/><rich:spacer height="10px"></rich:spacer><br/>
                            <h:inputText size="25" maxlength="30"
                                         value="#{disciplina.disciplina.departamento}"
                                         required="true" requiredMessage="#{messages.departamento}"/>
                        </div>                
                       <br />
                       <div class="summaryButton" align="right">
                            <h:commandLink action="#{disciplina.create}" value="Cadastrar" styleClass="button"/>
                            <h:outputText value="    "/>
                            <h:commandLink action="#{disciplina.listSetup}" styleClass="button" value="Cancelar" immediate="true"/>
                       </div>
                </h:form>
        </ui:define>
      </ui:composition>
</html>
